﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Runtime.Serialization;

namespace Entity
{
    /// <summary>
    /// 方法执行结果
    /// </summary>
    [DataContract]
    public class ExecuteResult
    {
        /// <summary>
        /// 返回状态码： 1-成功；其他失败
        /// </summary>
        [DataMember]
        public int OutCode { get; set; }

        /// <summary>
        /// 错误信息
        /// </summary>
        [DataMember]
        public string OutMessage { get; set; }
    }

    /// <summary>
    /// 方法执行结果
    /// </summary>
    /// <typeparam name="T"></typeparam>
    [DataContract]
    public class ExecultResult<T> : ExecuteResult
    {
        /// <summary>
        /// 方法执行返回的详细信息
        /// </summary>
        [DataMember]
        public T Data { get; set; }
    }
}
